package com.portal.config.guice;

import com.gaeig.base.GaeigModule;
import com.google.inject.Binder;
import com.portal.portal.PortalDriverService;
import com.portal.portal.PortalDriverServiceImpl;
import com.portal.portal.config.service.DriverBasicInfoService;
import com.portal.portal.config.service.DriverBasicInfoServiceImpl;
import com.portal.portal.config.service.DriverPortalURLParseService;
import com.portal.portal.config.service.DriverPortalURLParseServiceImpl;
import com.portal.portal.config.service.DriverRenderService;
import com.portal.portal.config.service.DriverRenderServiceImpl;
import com.portal.portal.config.service.DriverSupportedModesService;
import com.portal.portal.config.service.DriverSupportedModesServiceImpl;
import com.portal.portal.config.service.DriverWindowStateService;
import com.portal.portal.config.service.DriverWindowStateServiceImpl;

public class PortalBindingModule extends GaeigModule {

  @Override
  public void configureGuice(Binder binder) {
    this.configurePortalConfigGuice(binder);
    this.configPortalDriverGuice(binder);
  }
  
  private void configurePortalConfigGuice(Binder binder){
    binder.bind(DriverBasicInfoService.class).to(DriverBasicInfoServiceImpl.class);
    binder.bind(DriverPortalURLParseService.class).to(DriverPortalURLParseServiceImpl.class);
    binder.bind(DriverRenderService.class).to(DriverRenderServiceImpl.class);
    binder.bind(DriverSupportedModesService.class).to(DriverSupportedModesServiceImpl.class);
    binder.bind(DriverWindowStateService.class).to(DriverWindowStateServiceImpl.class);
  }
  
  private void configPortalDriverGuice(Binder binder){
    binder.bind(PortalDriverService.class).to(PortalDriverServiceImpl.class);
  }
  
  private void configPortletContainerGuice(Binder binder){
    //binder.bind(PortalDriverService.class).to(PortalDriverServiceImpl.class);
  }
  
  
}